function create() {
    let index = Math.floor(Math.random() * 16);
    while (imgs[index].getAttribute('value') != 0) {
        index = Math.floor(Math.random() * 16);
    }
        let random = Math.random() < 0.9 ? 2 : 4;
    imgs[index].setAttribute('value',random);
    imgs[index].setAttribute('src','./img/cube_' + random + '.png');
    
}